#ifndef DICOMEDITOR_H
#define DICOMEDITOR_H

#include <QWidget>
#include "editorinterface.h"
#include "dicomeditor_global.h"

namespace Ui {
class DicomEditor;
}

class DICOMEDITORSHARED_EXPORT DicomEditor : public QWidget, public EditorInterface
{
    Q_OBJECT
    Q_PLUGIN_METADATA(IID EditorPlugin_iid)
    Q_INTERFACES(EditorInterface)
public:
    explicit DicomEditor(QWidget *parent = 0);
    ~DicomEditor();

    QObject *getObject() { return this; }
    void setFileFormat(DcmFileFormat *dff);
    void setEditorHook(EditorProc proc, void *userData) { m_proc = proc; m_userData = userData; }

private slots:
    void on_okBtn_clicked();
    void on_cancelBtn_clicked();

private:
    void init();

    Ui::DicomEditor *ui;

    EditorProc m_proc;
    void *m_userData;
};

#endif // DICOMEDITOR_H
